﻿<div ng-controller="tokenBillController">
    <div class="wrapper border-bottom white-bg page-heading">
        <div class="col-lg-pull-12">
            <ol class="breadcrumb">
                <li><a ui-sref="app.token_bill.list">分佣记录</a></li>
                <li class="active" ng-bind="breadcrumb">详情</li>
            </ol>
        </div>
    </div>

    <form class="form-horizontal row">
        <div class="form-group">
            <div class="col-sm-6">
                <label class="col-sm-4 control-label">发起人</label>
                <div class="col-sm-8 form-control-static">
                    {{model.city_company_mobile}}
                </div>
            </div>
            <div class="col-sm-6">
                <label class="col-sm-4 control-label">分佣状态</label>
                <div class="col-sm-8 form-control-static">
                    {{model.e_maid_status_desc}}
                </div>
            </div>
        </div>
        <div class="form-group">
            <div class="col-sm-6">
                <label class="col-sm-4 control-label">总分佣金额</label>
                <div class="col-sm-8 form-control-static">
                    {{model.total_commission}}
                </div>
            </div>
            <div class="col-sm-6">
                <label class="col-sm-4 control-label">分佣类型</label>
                <div class="col-sm-8 form-control-static">
                    {{model.user_type_desc}}
                </div>
            </div>
        </div>
        <div class="form-group">
            <div class="col-sm-6">
                <label class="col-sm-4 control-label">邀请人</label>
                <div class="col-sm-8 form-control-static">
                    {{model.apply_merchant_name}}
                </div>
            </div>
            <div class="col-sm-6">
                <label class="col-sm-4 control-label">申请开通时间</label>
                <div class="col-sm-8 form-control-static">
                    {{model.create_time}}
                </div>
            </div>
        </div>
        <div class="form-group">
            <div class="col-sm-6">
                <label class="col-sm-4 control-label">分佣发起时间</label>
                <div class="col-sm-8 form-control-static">
                    {{model.launch_time}}
                </div>
            </div>

        </div>

    </form>
    <h4>分佣记录</h4>
    <div class="panel panel-default" ng-repeat="item in model.token_bill_detials">
        <div class="panel-body">
            <form name="_form">
                <div class="form-group ">
                    <label class="col-sm-2 control-label">分佣账号</label>
                    <div>
                        <div> {{item.merchant_name}}</div>
                    </div>
                </div>
                <div class="form-group ">
                    <label class="col-sm-2 control-label">分佣角色</label>
                    <div>
                        <div> {{item.merchant_user_type_desc}}</div>
                    </div>
                </div>
                <div class="form-group ">
                    <label class="col-sm-2 control-label">确认状态</label>
                    <div>
                        <div style="{{item.is_comfirm?'color:#0000ff':'color:#f44336'}};display:inline">{{item.is_comfirm?"已确认":" 未确认"}}</div>
                        <div style="display:inline;padding: 0 200px 0;"><button ng-if="!item.is_comfirm" ng-click="confirm(item)" class="btn btn-primary btn-sm"> 确认</button></div>
                    </div>
                    
                </div>
                <div class="form-group ">
                    <label class="col-sm-2 control-label">确认凭证</label>
                    <div ng-if="item.comfirm_transferVoucher==null||item.comfirm_transferVoucher==''">
                        <div style="color:#0000ff">
                            未上传
                        </div>
                    </div>
                    <div ng-if="item.comfirm_transferVoucher!=null&&item.comfirm_transferVoucher!=''">
                        <img ng-src="{{site.img_url+item.comfirm_transferVoucher}}" class="img-thumbnail" ng-show="item.transfer_voucher" width="20" height="20">
                        <a  ng-click="open_img(item.comfirm_transferVoucher)">预览</a>
                    </div>
                </div>
                <div class="form-group ">
                    <label class="col-sm-2 control-label">真实姓名</label>
                    <div>
                        <div>{{item.recivables_info.account_name}}</div>
                    </div>
                </div>
                <div class="form-group">
                    <label class="col-sm-2 control-label">银行卡号</label>
                    <div>
                        <div>{{item.recivables_info.card_no}}</div>
                    </div>
                </div>
                <div class="form-group ">
                    <label class="col-sm-2 control-label">银行信息</label>
                    <div>
                        <div>{{item.recivables_info.bank_name}}</div>
                    </div>
                </div>
                <div class="form-group ">
                    <label class="col-sm-2 control-label">支行地址</label>
                    <div>
                        <div>{{item.recivables_info.region_name+item.recivables_info.branch_name}}</div>
                    </div>
                </div>
                <div class="form-group ">
                    <label class="col-sm-2 control-label">微信二维码</label>
                    <div>
                        <img ng-if="item.recivables_info.wechat_qr_url!=null"  ng-src="{{site.img_url+item.recivables_info.wechat_qr_url}}" class="img-thumbnail" ng-show="item.recivables_info.wechat_qr_url" width="20" height="20">
                        <!--<div>{{item.recivables_info.wechat_qr_url==null?"&ensp; ":item.recivables_info.wechat_qr_url}}</div>-->
                        <a ng-if="item.recivables_info.wechat_qr_url!=null" ng-click="open_img(item.recivables_info.wechat_qr_url)">预览</a>
                    </div>
                </div>
                <div class="form-group ">
                    <label class="col-sm-2 control-label">支付宝账号</label>
                    <div>
                        <div>{{item.recivables_info.ali_pay_account==null?"&ensp; ":item.recivables_info.ali_pay_account}}</div>
                    </div>
                </div>
                <div class="form-group ">
                    <label class="col-sm-2 control-label">分佣比例</label>
                    <div>
                        <div>{{item.proportion*100}}%</div>
                    </div>
                </div>
                <div class="form-group ">
                    <label class="col-sm-2 control-label">分佣金额</label>
                    <div>
                        <div>{{item.commission}}</div>
                    </div>
                </div>
                <div class="form-group ">
                    <label class="col-sm-2 control-label">转账凭证</label>
                    <div ng-if="item.transfer_voucher==null||item.transfer_voucher==''">
                        <div style="color:#0000ff">
                            未上传
                        </div>
                    </div>
                    <div ng-if="item.transfer_voucher!=null&&item.transfer_voucher!=''">
                        <img ng-src="{{site.img_url+item.transfer_voucher}}" class="img-thumbnail" ng-show="item.transfer_voucher" width="20" height="20">
                        <a  ng-click="open_img(item.transfer_voucher)">预览</a>
                    </div>
                </div>
            </form>
        </div>
    </div>
    <div class="form-group form-group-sm">
        <label class="col-sm-2 control-label"></label>
        <div class="col-sm-3">
            <button ng-click="goBack()" class="btn btn-primary btn-sm"><i class="fa fa-rotate-left"></i> 返回</button>
        </div>
    </div>
</div>
<script type="text/ng-template" id="imgshow.html">
    <div class="modal-header">
        <h3 class="modal-title">图片</h3>
        <img src="{{site.img_url+img_url}}" width="500" />
    </div>

</script>

